<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="Taranis AI - Open-Source Intelligence leveraging AI">
    <meta name="keywords" content="AI, Taranis, assistant, artificial intelligence, platform">
    <title>Taranis AI</title>
    <link rel="stylesheet" href="{{ url_for('static', filename='css/tailwind.css') }}">

    <script src="{{ url_for('static', filename='vendor/vendor.bundle.js') }}"></script>
    <link rel="stylesheet" href="{{ url_for('static', filename='vendor/vendor.bundle.css') }}">

    <script src="{{ url_for('static', filename='js/main.js') }}" defer></script>
    <meta name="htmx-config" content='{"selfRequestsOnly": false}' />
    {% block head %}
    {% endblock head %}
  </head>

  <body class="flex bg-base-300 min-h-screen"
        hx-ext="response-targets"
        x-data="{ sidebarOpen: {{ 'true' if _show_sidebar else 'false' }}, init() { if (window.self !== window.top) this.sidebarOpen = false } }">
    <!-- Sidebar -->
    {% include "partials/sidebar.html" %}

    <!-- Navigation Bar -->
    <header id="navbar" class="fixed top-0 left-0 right-0 h-16 bg-base-200 flex items-center justify-between px-4 z-30 navbar">
      {% include "partials/navbar.html" %}
    </header>

    <!-- Main Content -->
    <main x-bind:class="{ 'ml-64 max-w-[calc(100vw-16rem)]': sidebarOpen }" class="pt-16 transition-all w-full max-w-full min-w-0">
      <div class="container mx-auto w-full max-w-full">
        {% block content %}
        {% endblock content %}
        {% include "notification/index.html" %}
      </div>
    </main>
  </body>
</html>
